1. Technical Field
The present invention relates in general to the field of data processing systems. Particularly, the present invention relates to the field of sharing resources within data processing systems.
2. Description of the Related Art
One of the greatest challenges of today's data processing systems is the efficient synchronization and arbitration of shared resources. Modern data processing systems typically include multiple processing units that frequently share resources, such as system memory and cache memory.
Generally, programs that take advantage of multi-processor architectures are referred to as “parallel programs”. A “task” is an arbitrarily defined piece of work performed by the parallel program. A “process” (herein utilized interchangeably with “thread”) is an abstract entity that performs tasks. A parallel program includes multiple cooperating processes that perform tasks in the program. Tasks are assigned to processes or threads by some assignment mechanism implemented in software, hardware, or a combination thereof. The method in which processes perform their assigned tasks is through execution via physical processing units. Processes may need to synchronize with each other to perform their assigned tasks and share resources within the data processing system, such as memory.
The problem with sharing resources is that often, a first thread may require data stored in a memory location that is locked by a second thread within the system. As well-known in the prior art in such a situation, the first thread will continually try to access the locked memory location until successful. However, continually retrying accesses to an inaccessible memory location wastes processing unit resources that could be put to better use through the performance of useful work. Therefore, there is a need to improve the handling of conditions within modern data processing systems during which processing units are not able to proceed with useful work due to the temporary unavailability of a shared resource.